.PHONY:build burn

mbr_source=boot/mbr.S
mbr_target=boot/mbr.bin
loader_source=boot/loader.S
loader_target=boot/loader.bin
hard_disk=/home/lhj/Public/bochs/bin/hd60M.img

build:
		nasm -I boot/include/ -o $(mbr_target) $(mbr_source)
		nasm -I boot/include/ -o $(loader_target) $(loader_source)
burn:
		dd if=$(mbr_target) of=$(hard_disk) bs=512 count=1 conv=notrunc
		dd if=$(loader_target) of=$(hard_disk) bs=512 count=1 seek=2 conv=notrunc
